package com.example.project.dao;

import com.example.project.entity.Menu;
import com.example.project.entity.RequestInto;
import com.example.project.entity.User;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface UserInterface {
    User login(User user);

    User queryUser(String token);

    int updateToken(User user);  //修改token

    List<Menu> queryTable(@Param("user") User user,
                          @Param("params") RequestInto params);

    long queryTableCount(@Param("user") User user, @Param("params") RequestInto params);

    User queryUser(User user);

    void adduser(User user);

    void edituser(@Param("user") User user);

    void deluser(@Param("user") User user);

    //    查找管理员
    List<User> getadmin();

    long adminCount();
}
